<!doctype html>

<html  lang="zh" xmlns:th="http://www.thymeleaf.org">


<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">

<title>收藏夹</title>
<link rel="shortcut icon" type="image/ico" th:href="@{/images/title_icon.png}"/>

<link rel="stylesheet" th:href="@{/css/font-awesome-min.css}">
<link rel="stylesheet" th:href="@{/css/bootstrap-min.css}">
<link rel="stylesheet" th:href="@{/css/normalize.css}">
<link rel="stylesheet" th:href="@{/css/animate.css}">
<link rel="stylesheet" th:href="@{/css/lity.css}">
<link rel="stylesheet" th:href="@{/css/slick-nav.css}" >
<link rel="stylesheet" th:href="@{/css/slick-slider.css}">
<link rel="stylesheet" th:href="@{/css/theme.css}">

<link th:href="@{/style.css}" rel="stylesheet">
<link th:href="@{/css/responsive.css}" rel="stylesheet">
<script th:src="@{/js/vendor/modernizr.js}"></script>

<!--设计图表所需的js-->
<script type="text/javascript" th:src="@{/js/jquery.min.js}"></script>
<script type="text/javascript" th:src="@{/js/highcharts.js}"></script>
<script type="text/javascript" th:src="@{/js/favorites.js}"></script>
<style type="text/css">
	.btn-success {
		margin: 10px auto;
		font-size: 10px;
	}
</style>
</head>
<body data-spy="scroll" data-target=".mainmenu-area" data-offset="50">
<!--<p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>-->
<div class='cursor'  id="cursor"></div>
<div class='cursor2' id="cursor2"></div>
<div class='cursor3' id="cursor3"></div>
<div class="preloader">
	<img th:src="@{/images/preloader.gif}" src="images/preloader.gif" alt="preloader">
</div>
<div class="full-wrapper">
	<div th:replace="~{commons/bar :: topbar}"></div>

	<div class="live_wrap">
		<div class="u_header">
			<h1>个人中心</h1>
		</div>
		<div>
			<div th:replace="~{commons/bar :: left(active='Favorites')}"></div>

			<div class="u_mainbody">
				<div class="user_myprofile user_info_page">
					<div class="togglebtn clearfix ">
						<i class="f1"></i>
						<p class="f1 " style="padding-top: 4px;">收藏夹</p>
		   			</div>
				</div>
				<div  class="consume_nr" style="display:block">
					<table cellspacing="0" cellpadding="0" class="aui_room_table">
						<thead>
							<tr>
								<th width="40%">商品名称</th>
								<th width="13%">商品ID</th>
								<th width="15%">收藏时间</th>
								<th width="12%">商品价格</th>
								<th width="10%">历史价格</th>
								<th width="10%">取消收藏</th>
							</tr>
						</thead>
						<tbody>
							<tr th:each="list:${emps}">
								<td  th:text="${list.goodsName}"></td>
								<td th:text="${list.goodsId}"></td>
								<td th:text="${#dates.format(list.time,'yyyy-MM-dd')}"></td>
								<td th:text="${list.goodsPrice}"></td>
								<td><button id="jg" type="button" class="btn btn-success" onclick="commit(this)" th:value="${list.goodsId}">历史价格</button></td>
<!--								<a th:href="@{/historyPrice(Id=${list.goodsId})}" target="_blank"></a>-->
								<td><button id="delete" type="button" class="btn btn-success" onclick="deleteFavorite(this)" th:value="${list.goodsId}">删 除</button></td>
							</tr>
							<tr  th:if="${emps == null}">
								<td style="text-align: center">暂无历史记录</td>
								<td></td>
								<td></td>
								<td></td>
								<td></td>
							</tr>
						</tbody>
					</table>
					<p th:if="${emps != null}" class="page fr">
						<span id="page-link">
							<a th:if="${pagenum != 1}" th:href="@{/favorites/1}">首页</a>
							<a th:if="${pagenum != 1}" th:href="@{/favorites/} + ${pagenum-1}">上一页</a>
							<a th:text="${pagenum}" th:href="@{/favorites/}+${pagenum}" class="ui-button current ui-state-disabled">1</a>
							<a th:if="${pagenum != count}" th:text="${pagenum + 1}" th:href="@{/favorites/}+${pagenum+1}">2</a>
							<span th:if="${pagenum != count}">. . . .</span>
							<a th:if="${ pagenum != count}" th:text="${count}" th:href="@{/favorites/}+${count}"></a>
							<a th:text="${pagenum != count}?'下一页':'已到尾页'" th:href="@{/favorites/}+${pagenum+1}">下一页</a>
						</span>
					</p>
				</div>
			</div>
		</div>
	</div>



	
	<footer class="footer-area rboom">
		
		<div class="footer-bottom">
			<div class="container">
				<div class="row">
					<div class="col-lg-6 offset-lg-3 text-center">
						<div class="copyright">
							<p>Copyright &copy; 2020. Bi Jia Wang All rights reserved.</p>
						</div>
					</div>
				</div>
			</div>
		</div>
	</footer>
</div>
<script th:src="@{/js/vendor/jquery-min.js}" src="js/vendor/jquery-min.js"></script>
<script th:src="@{/js/popper-min.js}" src="js/popper-min.js"></script>
<script th:src="@{/js/bootstrap-min.js}" src="js/bootstrap-min.js"></script>
<script th:src="@{/js/lity-min.js}" src="js/lity-min.js"></script>
<script th:src="@{/js/slick-slider-min.js}" src="js/slick-slider-min.js"></script>
<script th:src="@{/js/slick-nav.js}" src="js/slick-nav.js"></script>
<script th:src="@{/js/wow-min.js}" src="js/wow-min.js"></script>
<script th:src="@{/js/ajaxchimp.js}" src="js/ajaxchimp.js"></script>
<script th:src="@{/js/script.js}" src="js/script.js"></script>


<script type="text/javascript">
	function commit(e) {
		var url = "/historyPrice?Id=" + $(e).attr("value");
		window.open(url,"_blank");
	}

</script>
<script type="text/javascript">
	function deleteFavorite(e) {
		var url = "/deleteFavorites?Id=" + $(e).attr("value");
		window.open(url,"_self");
	}
</script>
</body>


</html>
